from selenium import webdriver
import time

driver = webdriver.Chrome()

driver.get('https://www.douban.com/')

driver.set_window_size(1500, 1200)

login_frame = driver.find_element_by_xpath('//div[@class="login"]/iframe')

driver.switch_to.frame(login_frame)

time.sleep(2)

driver.find_element_by_xpath('//li[@class="account-tab-account"]').click()

driver.find_element_by_id('account-form-remember').click()


driver.find_element_by_id('username').send_keys('xxxx')
driver.find_element_by_id('password').send_keys('xxxx')

driver.find_element_by_class_name('btn-account').click()




